

/**
 * 上传图片函数, 支持BJUI自带上传控件
 * @param file
 * @param data
 * @param $upload
 */
function custom_pic_upload_success(file, data, $upload) {
    var json = $.parseJSON(data)
    if (json[BJUI.keys.statusCode] == BJUI.statusCode.ok) {
        var pic = json.filename
        $upload.next().html('<img src="' + pic + '" width="80" />')
    }else{
        $(this).alertmsg('error', '上传图片失败！'+json.message)
    }
}




/**
 * 导出提示弹窗
 */
function exportDialog(id, title){
    var option = {};
    option['id'] = id || 'exportDialog'+Math.random();                // 进度条id
    option['url'] = "?s=/Index/exportDialog.html";             // 显示进度条
    option['title'] = title || '导出提示弹窗';          // 进度条标题
    option['width'] = 600;
    option['height'] = 100;
    option['mask'] = true;
    $(this).dialog(option);
}